import { log as ccLog, warn as ccWarn, error as ccError } from 'cc';
import { EDITOR } from 'cc/env';
enum Platform { H5, Android, Ios, Pc }
Object.assign((globalThis as any).aa ||= {}, {
    Platform: Platform,
    log: EDITOR ? ccLog : console.log,
    warn: EDITOR ? ccWarn : console.warn,
    error: EDITOR ? ccError : console.error,
    gameName: '开心消消乐',
    current: Date.now(),
});
declare global {
    module aa {
        enum Platform { H5, Android, Ios, Pc } //将枚举扩展到全局命名空间aa中
        function log(...data: any[]): void; //将自定义log扩展到全局命名空间aa中
        function warn(...data: any[]): void; //将自定义warn扩展到全局命名空间aa中
        function error(...data: any[]): void; //将自定义error扩展到全局命名空间aa中
        let gameName: string; //将string扩展到全局命名空间aa中
        let current: number;  //将number扩展到全局命名空间aa中
    }
}